package com.xiaofeixia.common;

public class RespEntity {
    private Integer code;//状态码
    private String message;//信息
    private Object data;  //返回的数据信息
    private String appid;

    public RespEntity(RespCode respCode) {
        this.code = respCode.getCode();
        this.message = respCode.getMsg();
        this.appid=respCode.getAppid();
    }
    public RespEntity(RespCode respCode,Object data){
        this(respCode);  //controller 传过来的状态信息
        this.data=data;
    }
    /*public RespEntity(RespCode respCode, Object data) {  // respCode的数据就是成功的标志 user的数据给了data
        this(respCode);
        this.data = data;
    }*/

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }
}
